<?php

declare(strict_types=1);

namespace Plugin\Attractions\Broadcast\Model\Broadcast_devices;

use Hyperf\DbConnection\Model\Model;

/**
 * @property int $id 主键ID
 * @property string $device_name 设备名称
 * @property string $device_model 设备型号
 * @property string $device_brand 设备品牌
 * @property string $device_sn 设备序列号
 * @property float $longitude 经度
 * @property float $latitude 纬度
 * @property float $altitude 海拔高度
 * @property string $ip_address IP地址
 * @property int $port 端口号
 * @property string $secret 密钥
 * @property string $mac_address MAC地址
 * @property int $online_status 在线状态：1-离线，2-在线
 * @property string $last_online_time 最后在线时间
 * @property string $device_group 设备分组
 * @property int $maintenance_status 维护状态：1-正常，2-需要维护，3-维护中，4-报废
 * @property string $remark 备注
 */
class BroadcastDevices extends Model
{
    public bool $timestamps = false;
    /**
     * The table associated with the model.
     */
    protected ?string $table = 'broadcast_devices';

    /**
     * The attributes that are mass assignable.
     */
    protected array $fillable = ['id', 'device_name', 'device_model', 'device_brand', 'device_sn', 'longitude', 'latitude', 'altitude', 'ip_address', 'port', 'secret', 'mac_address', 'online_status', 'last_online_time', 'device_group', 'maintenance_status', 'remark'];

    /**
     * The attributes that should be cast to native types.
     */
    protected array $casts = ['id' => 'integer', 'longitude' => 'float', 'latitude' => 'float', 'altitude' => 'float', 'port' => 'integer', 'online_status' => 'integer', 'maintenance_status' => 'integer'];
}
